/**
 * 
 */
package net.chrisrichardson.ormunit.hibernate;

import java.util.Set;

/**
 * Used to specify field or property access
 * @author cer
 *
 */
public enum AccessStrategy {

	FIELD {
		public Set<String> getPersistableProperties(Class type, Class mappedSuper) {
			return ClassPropertyUtil.getPersistableFields(type, mappedSuper);
		}
		public String getName() {
			return "field"; 
		}
	},
	PROPERTY {
		public Set<String> getPersistableProperties(Class type, Class mappedSuper) {
			return ClassPropertyUtil.getPersistableProperties(type, mappedSuper);
		}
		public String getName() {
			return "property"; 
		}
	};
	
	public abstract Set<String> getPersistableProperties(Class type, Class mappedSuper);

	public abstract String getName();
	
}